home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1993…ch: Other People's Memory / ADC Developer CD (1993-03) (''Other People's Memory'')_iso / Dev.CD Mar 93.iso / Development Platforms / Apple II / Essentials / APW Interfaces / CInclude / Desk.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-03-04  |  3.9 KB  |  119 lines  |  [TEXT/MPS ]

  1. /********************************************
  2. ; File: Desk.h
  3. ;
  4. ;
  5. ; Copyright Apple Computer, Inc.1986-91
  6. ; All Rights Reserved
  7. ;
  8. ********************************************/
  9.  
  10. #ifndef __TYPES__
  11. #include <TYPES.h>
  12. #endif
  13.  
  14. #ifndef __QUICKDRAW__
  15. #include <QUICKDRAW.h>
  16. #endif
  17.  
  18. #ifndef __EVENT__
  19. #include <EVENT.h>
  20. #endif
  21.  
  22. #ifndef __DESK__
  23. #define __DESK__
  24.  
  25.  
  26. /* Error Codes */
  27. #define daNotFound 0x0510        /* desk accessory not found */
  28. #define notSysWindow 0x0511        /* not the system window */
  29. #define deskBadSelector 0x0520    /* bad selector for GetDeskAccInfo */
  30.  
  31. /* NDA Action Codes */
  32. #define eventAction 0x0001
  33. #define runAction 0x0002
  34. #define cursorAction 0x0003
  35. #define undoAction 0x0005
  36. #define cutAction 0x0006
  37. #define copyAction 0x0007
  38. #define pasteAction 0x0008
  39. #define clearAction 0x0009
  40. #define sysClickAction 0x000A
  41. #define optionalCloseAction 0x000B
  42.  
  43. /* SystemEdit Codes */
  44. #define undoEdit 0x0001
  45. #define cutEdit 0x0002
  46. #define copyEdit 0x0003
  47. #define pasteEdit 0x0004
  48. #define clearEdit 0x0005
  49.  
  50. /* constants for GetDeskAccInfo */
  51. #define getCDAinfo 0x8000
  52. #define getNDAinfo 0x0000
  53. #define daRefIsWindPtr 0x0001
  54. #define daRefIsIndex 0x0000
  55.  
  56. /* constants for GetDeskGlobal */
  57. #define deskGlobalWindow 0x0000
  58.  
  59. /* constants for CallDeskAcc */
  60. #define daCallCDA 0x8000
  61. #define daCallNDA 0x0000
  62. #define daCallInit 0x0002
  63. #define daCallAction 0x0000
  64. /* #define daRefIsWindPtr 0x0001 */
  65. /* #define daRefIsIndex 0x0000 */
  66.  
  67. /* System Window structure for GetAuxWindInfo */
  68.  
  69. struct NDASysWindRecord {
  70.     Word status;            /* use 0, reserved for Desk Mgr */
  71.     LongProcPtr openProc;    /* reserved, use nil */
  72.     ProcPtr closeProc;        /* pointer to your Close routine */
  73.     ProcPtr actionProc;        /* pointer to your Action routine */
  74.     ProcPtr initProc;        /* reserved, use nil */
  75.     Word period;
  76.     Word eventMask;            /* your event mask, like for an NDA */
  77.     LongWord lastServiced;    /* reserved, use 0 */
  78.     LongWord windowPtr;        /* reserved, use 0 */
  79.     LongWord ndaHandle;        /* reserved, use 0 */
  80.     Word memoryID;            /* your memory ID, important! */
  81. };
  82. typedef struct NDASysWindRecord NDASysWindRecord, *NDASysWindRecPtr;
  83.  
  84. extern pascal void AddToRunQ() inline(0x1F05,dispatcher);
  85. extern pascal void ChooseCDA() inline(0x1105,dispatcher);
  86. extern pascal void CloseAllNDAs() inline(0x1D05,dispatcher);
  87. extern pascal void CloseNDA() inline(0x1605,dispatcher);
  88. extern pascal void CloseNDAByWinPtr() inline(0x1C05,dispatcher);
  89. extern pascal void DeskBootInit() inline(0x0105,dispatcher);
  90. extern pascal void DeskReset() inline(0x0505,dispatcher);
  91. extern pascal void DeskShutDown() inline(0x0305,dispatcher);
  92. extern pascal void DeskStartUp() inline(0x0205,dispatcher);
  93. extern pascal Boolean DeskStatus() inline(0x0605,dispatcher);
  94. extern pascal Word DeskVersion() inline(0x0405,dispatcher);
  95. extern pascal void FixAppleMenu() inline(0x1E05,dispatcher);
  96. extern pascal Pointer GetDAStrPtr() inline(0x1405,dispatcher);
  97. extern pascal Word GetNumNDAs() inline(0x1B05,dispatcher);
  98. extern pascal void InstallCDA() inline(0x0F05,dispatcher);
  99. extern pascal void InstallNDA() inline(0x0E05,dispatcher);
  100. extern pascal Word OpenNDA() inline(0x1505,dispatcher);
  101. extern pascal void RemoveCDA() inline(0x2105,dispatcher);
  102. extern pascal void RemoveFromRunQ() inline(0x2005,dispatcher);
  103. extern pascal void RemoveNDA() inline(0x2205,dispatcher);
  104. extern pascal void RestAll() inline(0x0C05,dispatcher);
  105. extern pascal void RestScrn() inline(0x0A05,dispatcher);
  106. extern pascal void SaveAll() inline(0x0B05,dispatcher);
  107. extern pascal void SaveScrn() inline(0x0905,dispatcher);
  108. extern pascal void SetDAStrPtr() inline(0x1305,dispatcher);
  109. extern pascal void SystemClick() inline(0x1705,dispatcher);
  110. extern pascal Boolean SystemEdit() inline(0x1805,dispatcher);
  111. extern pascal Boolean SystemEvent() inline(0x1A05,dispatcher);
  112. extern pascal void SystemTask() inline(0x1905,dispatcher);
  113.  
  114. extern pascal void GetDeskAccInfo() inline(0x2305,dispatcher);
  115. extern pascal Word CallDeskAcc() inline(0x2405,dispatcher);
  116. extern pascal LongWord GetDeskGlobal() inline(0x2505,dispatcher);
  117.  
  118. #endif
  119.